<%@ taglib prefix="s" uri="/struts-tags"%>

<ul data-role="listview">
	<li>
		<ul class="rslides" id="slider1">
					<s:if test="%{entityBean.gallery!=null}">
						<s:iterator begin="1" value="entityBean.gallery.medias">
						<li><img
							src="${url}"
							alt="">
							<div class="caption">${entityBean.name}</div>
						</li>
						</s:iterator>
			</s:if>

		</ul>
	</li>

<!-- 	<li> -->
<!-- 		<div class="align-center"> -->
<!-- 			<button -->
<%-- 				class="custom-btn ui-btn ui-btn-c ui-btn-inline ui-corner-all ui-icon-ction ui-btn-icon-left ui-data-mini">${entityBean.web}</button> --%>
<!-- 		</div> -->
<!-- 	</li> -->


	<li class="map-li"><div class="title2 color-gray">Dove</div><div class="title1">${entityBean.address}</div>
    				<img id="map-image" src="" /> 
    				</li>
    				<s:if test="%{entityBean.phone !=null && entityBean.phone != ''}">
    					<li><div class="title2 color-gray">Telefono</div><div class="title1"><a href="tel:${entityBean.phone}"> ${entityBean.phone}</a></div></li>
    				</s:if>
    				<s:if test="%{entityBean.web !=null && entityBean.web != ''}">
    					<li><div class="title2 color-gray">Web</div><div class="title1"><a href="${entityBean.web}">${entityBean.web}</a></div></li>
    				</s:if>
    				<s:if test="%{entityBean.email !=null && entityBean.email != ''}">
    					<li><div class="title2 color-gray">Email</div><div class="title1">${entityBean.email}</div></li>
    				</s:if>
    	<li>
		<div data-role="collapsible" data-collapsed-icon="carat-r"
			data-expanded-icon="carat-d" data-inset="false" data-mini="true"
			data-iconpos="right">
			<h3 class="title2 color-gray">Descrizione</h3>
			<p class="white-space-normal">${entityBean.description}</p>
		</div>

	</li>
</ul>






<script type="text/javascript">
	$(document).on('pageinit', function() {
		$("#slider1").responsiveSlides({
			maxwidth : 600,
			speed : 800
		});
		$.mobile.ajaxEnabled = false;
	});
	$("#map-image").attr("src","http://maps.googleapis.com/maps/api/staticmap?center=${entityBean.address},${entityBean.city.name}&zoom=15&size="+$(window).width()+"x150&markers=${entityBean.address},${entityBean.city.name}&sensor=false");

</script>

